package com.wing.purchase.model.request;

import com.wing.purchase.model.entity.PurchaseEnquiry;
import com.wing.purchase.model.entity.PurchaseEnquiryDetail;
import com.wing.purchase.model.entity.PurchaseRequisitionsDetail;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;

/**
 * 询价单Form
 *
 * @author
 */
@Data
@NoArgsConstructor
@Accessors(chain = true)
public class PurchaseEnquiryForm {

    /**
     * ID
     */
    private Long id;

    /**
     * 创建者
     */
    private Long creator;

    /**
     * 修改者
     */
    private Long modifier;

    /**
     * 创建人
     */
    private String creatorName;

    /**
     * 修改人
     */
    private String modifierName;

    /**
     * 询价单号
     */
    private String inquiryNo;

    /**
     * 请购单id
     */
    private Long purchaseRequisitionsId;

    /**
     * 供应商ids
     */
    private String supplierIds;

    /**
     * 状态
     */
    private PurchaseEnquiry.Status status;

    /**
     * 询价状态
     */
    private PurchaseEnquiry.EnquiryStatus enquiryStatus;

    /**
     * 是否公开
     */
    private Boolean hasPublic;

    /**
    * 询价结束时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime inquiryEndTime;

    /**
    * 交货开始时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime deliveryStartTime;

    /**
    * 交货截止时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime deliveryTime;

    /**
     * 联系人
     */
    private String contactPerson;

    /**
     * 联系人电话
     */
    private String contactNumber;

    /**
     * 采购计划详情集合
     */
    private List<PurchaseEnquiryDetail> purchaseEnquiryDetails = new ArrayList<>();

    public interface Add{}

    public interface Update{}
}
